import { handlerKey } from "../share/index"

export function emit(instance, event, ...arg) {
  const {props} = instance
  const handlerName = handlerKey(event)
  const handler = props[handlerName]
  handler?.(...arg)
}